<template>
    <svg class="ne-comp-svg" viewBox="0 0 1024 1024" :width="width" :height="height">
        <path v-for="(item, index) in svgPathMap[type]" :key="index" :d="item"></path>
    </svg>
</template>

<script>
export default {
    name: 'ne-comp-svg',
    props: {
        type: {
            type: String,
            required: true
        },
        width: {
            type: Number,
            required: false,
            default: 200
        },
        height: {
            type: Number,
            required: false,
            default: 200
        }
    },
    data () {
        return {
            svgPathMap: {
                reset: [
                    'M103.78571416 338.42857168a392.78571416 392.78571416 0 0 0 185.78571416 529.07142832L242 962 512 ' +
                    '897.71428584 390.5 666.28571416l-49.5 98.35714336a299.57142832 299.57142832 0 0 ' +
                    '1-143.35714248-177.42857168A270.64285752 270.64285752 0 0 1 216.28571416 383.42857168a321.42857168 ' +
                    '321.42857168 0 0 1 251.35714336-167.78571416L411.71428584 109.57142832A443.57142832 443.57142832 ' +
                    '0 0 0 103.14285752 338.42857168z m578.57142832-82.92857168a298.28571416 298.28571416 0 0 1 146.5714292 ' +
                    '178.07142832 270.64285752 270.64285752 0 0 1-18.64285752 201.21428584 321.42857168 321.42857168 0 0 ' +
                    '1-257.14285664 171l55.9285708 106.71428584a444.21428584 444.21428584 0 0 0 314.35714336-230.14285752 ' +
                    '379.92857168 379.92857168 0 0 0 25.71428584-278.35714248 418.5 418.5 0 0 0-217.28571504-252l45.64285752-90' +
                    'L505.57142832 126.28571416l122.78571416 232.71428584 51.42857168-104.14285752z'
                ],
                add: [
                    'M512 0C229.831111 0 0 229.831111 0 512S229.831111 1024 512 1024 1024 794.168889 1024 512 794.168889 ' +
                    '0 512 0z m0 955.733333C266.24 955.733333 68.266667 757.76 68.266667 512S266.24 68.266667 512 68.266667 ' +
                    '955.733333 266.24 955.733333 512 757.76 955.733333 512 955.733333z',
                    'M750.933333 477.866667h-204.8v-204.8c0-18.204444-15.928889-34.133333-34.133333-34.133334S477.866667 ' +
                    '254.862222 477.866667 273.066667v204.8h-204.8c-18.204444 0-34.133333 15.928889-34.133334 34.133333S254.862222 ' +
                    '546.133333 273.066667 546.133333h204.8v204.8c0 18.204444 15.928889 34.133333 34.133333 34.133334S546.133333 ' +
                    '769.137778 546.133333 750.933333v-204.8h204.8c18.204444 0 34.133333-15.928889 34.133334-34.133333S769.137778 ' +
                    '477.866667 750.933333 477.866667z'
                ],
                minus: [
                    'M512 0C375.232 0 246.656 53.264 149.968 149.968 53.248 246.672-0.016 375.248-0.016 512s53.264 265.328 ' +
                    '149.984 362.016C246.656 970.736 375.232 1024 512 1024s265.344-53.264 362.032-149.968c96.72-96.704 ' +
                    '149.984-225.28 149.984-362.032s-53.264-265.328-149.984-362.016C777.344 53.264 648.768 0 512 0z m316.784 ' +
                    '828.768C744.176 913.392 631.664 960 512 960s-232.176-46.608-316.784-131.232C110.592 744.16 63.984 ' +
                    '631.664 63.984 512s46.608-232.16 131.232-316.768C279.824 110.608 392.336 64 512 64s232.176 46.608 ' +
                    '316.784 131.232C913.408 279.84 960.016 392.336 960.016 512s-46.608 232.16-131.232 316.768z',
                    'M800 480H224a32 32 0 0 0 0 64h576a32 32 0 0 0 0-64z'
                ]
            }
        };
    }
};
</script>

<style lang="scss" scoped>
.ne-comp-svg {
    display: block;
}
</style>
